package com.gxa.dao;

import com.gxa.pojo.Customer;

import java.math.BigDecimal;
import java.sql.SQLException;
import java.util.List;

public interface CustomerValueDao {
    /**
     * 查询客户信息
     * @param currentPage
     * @param pageSize
     * @return
     * @throws SQLException
     */
    List queryCustomer(Integer currentPage, Integer pageSize) throws SQLException;

    /**
     * 查询指定客户的所有订单信息
     * @param customer_name
     * @return
     * @throws SQLException
     */
    List queryOrder(String customer_name) throws SQLException;

    /**
     * 计算客户数量
     * @param customer_name
     * @return
     * @throws SQLException
     */
//    Integer countCustomer(String customer_name) throws SQLException;

    /**
     * 统计指定客户的总消费金额
     * @param customer_name
     * @return
     * @throws SQLException
     */
    BigDecimal getConsumeTotalMoney(String customer_name) throws SQLException;

    /**
     * 按条件搜索客户信息
     * @param currentPage
     * @param pageSize
     * @param customer_name
     * @param type
     * @return
     * @throws SQLException
     */
    List searchCustomer(Integer currentPage, Integer pageSize, String customer_name, String type) throws SQLException;

    /**
     * 查询指定客户的所有订单信息
     * @param currentPage
     * @param pageSize
     * @param customer_name
     * @return
     * @throws SQLException
     */
    List queryCustomerOrder(Integer currentPage, Integer pageSize, String customer_name) throws SQLException;
}
